﻿<Window x:Class="BoginyaJournal.Login"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:ff="clr-namespace:FunctionalFun.UI"
        xmlns:bb="clr-namespace:BoginyaJournal"
        xmlns:xc="clr-namespace:ExCastle.Wpf"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="{Binding Title}" Height="271" Width="436" WindowStyle="SingleBorderWindow" WindowStartupLocation="CenterScreen"
        xc:DialogCloser.DialogResult="{Binding DialogResult}"
        bb:WindowClosingBehavior.Closing="{Binding ClosingCommand}"
        >
        <Grid>
        <StackPanel>
            <StackPanel Orientation="Horizontal" Margin="0,50,10,0" HorizontalAlignment="Right">
                <TextBlock  Height="32" HorizontalAlignment="Left" Name="textBlock1" TextAlignment="Right" Text="Логін:" VerticalAlignment="Top" Width="122" Margin="0,5,10,0" FontSize="25" />
                <ComboBox Height="42" HorizontalAlignment="Left" Name="cmbLogin" VerticalAlignment="Top" Width="256"  ItemsSource="{Binding Path=UserList}" SelectedItem="{Binding Path=Selected}" FontSize="25" />
            </StackPanel>
            <StackPanel Orientation="Horizontal" Margin="0,10,10,0" HorizontalAlignment="Right">
                <TextBlock Height="32" HorizontalAlignment="Left" Name="textBlock2" Text="Пароль:" TextAlignment="Right" VerticalAlignment="Top" Width="122"  Margin="0,5,10,0" FontSize="25" />
                <PasswordBox Height="43" HorizontalAlignment="Left" Name="txtPassword" VerticalAlignment="Top" Width="256"  FontSize="25"  
                             ff:PasswordBoxAssistant.BindPassword="true" ff:PasswordBoxAssistant.BoundPassword="{Binding Path=Password, Mode=TwoWay, UpdateSourceTrigger=PropertyChanged}"/>
            </StackPanel>
            <StackPanel Orientation="Horizontal" Margin="0,20,0,0" FlowDirection="RightToLeft">
                <Button Command="{Binding Path=LogInCommand}" IsDefault="True" Name="btnLogin" Height="50" Width="150" Content="Увійти"  Margin="10,0,0,0" FontSize="25"></Button>
            </StackPanel>
        </StackPanel>
    </Grid>
</Window>
